package com.example.anliku.mapper;
import java.util.Date;
import org.apache.ibatis.annotations.Param;
import java.util.List;

import com.example.anliku.entity.Comment;
import org.apache.ibatis.annotations.Mapper;

@Mapper
public interface CommentMapper {
    int deleteByPrimaryKey(Integer commentId);

    int insert(Comment record);

    int insertSelective(Comment record);

    Comment selectByPrimaryKey(Integer commentId);

    int updateByPrimaryKeySelective(Comment record);

    int updateByPrimaryKey(Comment record);

    List<Comment> selectAll();

    int updateCommentStateAndCommentPassTimeByCommentId(@Param("updatedCommentState")Integer updatedCommentState,@Param("updatedCommentPassTime")Date updatedCommentPassTime,@Param("commentId")Integer commentId);


    int updateCommentStateAndCommentPassTimeAndIncCommentCheckIdByCommentId(@Param("updatedCommentState")Integer updatedCommentState,@Param("updatedCommentPassTime")Date updatedCommentPassTime,@Param("addedCommentCheckId")String addedCommentCheckId,@Param("commentId")Integer commentId);


    List<Comment> selectAllByCommentCaseId(@Param("commentCaseId")String commentCaseId);

    Integer countByCommentCaseId(@Param("commentCaseId")String commentCaseId);


}
